Comments and Line Continuation

CSL supports three different forms for comments. Multiline comments are enclosed between "/*" and "*/", while single line comments can follow either a double-slash "//" or a pound sign "#".

The following constructs must end with a line break:

  • Import directive

  • Formula

  • Rule

  • Message

  • Function definition

  • Set block

 

Line breaks within these constructs require use of the line continuation character (a space followed by an underscore--see below), except as follows:

  • Conditional expressions can contain a line break after a boolean expression that follows if.

  • Set blocks must contain a line break after each formula.

  • Foreach expressions must contain a line break after each formula.

CSL permits VB-style line continuation:

Copy
// A space followed by the underscore is line continuation
a_bool = (part.thickness > machine.minThickness) && _ 
    (part.thickness < machine.maxThickness)